package demo1;
class Animals{
    public String name ;
    public int age;
    public void eat (){
        System.out.println(this.name+"正在吃饭");
    }
}
class Dog extends Animals {//继承---is a what?

    public void bark () {
        System.out.println(this.name+"汪汪叫");
    }
}
class Cat extends Animals {

    public void bark () {
        System.out.println(this.name+"喵喵叫");
    }
}
public class Test {
    public static void main(String[] args) {

    }
}
